﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>

<asp:Content ID="registerTitle" ContentPlaceHolderID="TitleContent" runat="server">
  Register
</asp:Content>
<asp:Content ID="registerContent" ContentPlaceHolderID="MainContent" runat="server">

  <script type="text/javascript">
	$(function() {
		$("#birthDate").datepicker();
		$("#birthDate").datepicker('option', {dateFormat: "yy/mm/dd"});
	});
  </script>

  <h2>
    Create a New Account</h2>
  <p>
    Use the form below to create a new account.
  </p>
  <p>
    Passwords are required to be a minimum of
    <%=Html.Encode(ViewData["PasswordLength"])%>
    characters in length.
  </p>
  <%= Html.ValidationSummary("Account creation was unsuccessful. Please correct the errors and try again.") %>
  <% using (Html.BeginForm()) { %>
  <div>
    <fieldset>
      <legend>Account Information</legend>
      <p>
        <label for="email">
          Email:</label>
        <%= Html.TextBox("email") %>
        <%= Html.ValidationMessage("email") %>
      </p>
      <p>
        <label for="firstName">
          First Name:</label>
        <%= Html.TextBox("firstName") %>
        <%= Html.ValidationMessage("firstName") %>
      </p>
      <p>
        <label for="lastName">
          Last Name:</label>
        <%= Html.TextBox("lastName") %>
        <%= Html.ValidationMessage("lastName") %>
      </p>
      <p>
        <label for="callSign">
          Call Sign:</label>
        <%= Html.TextBox("callSign") %>
        <%= Html.ValidationMessage("callSign") %>
      </p>
      <p>
        <label for="birthDate">
          Date of birth:</label>
        <%= Html.TextBox("birthDate") %>
        <%= Html.ValidationMessage("birthDate") %>
      </p>
      <p>
        <label for="gender">
          Gender</label>
        <%= Html.DropDownList("genderId") %>
      </p>
      <p>
        <label for="password">
          Password:</label>
        <%= Html.Password("password") %>
        <%= Html.ValidationMessage("password") %>
      </p>
      <p>
        <label for="confirmPassword">
          Confirm password:</label>
        <%= Html.Password("confirmPassword") %>
        <%= Html.ValidationMessage("confirmPassword") %>
      </p>
      <p>
        <input type="submit" value="Register" />
      </p>
    </fieldset>
  </div>
  <% } %>
</asp:Content>
